<template>
<el-dialog
  title="提示"
  :visible.sync="isShow"
  width="30%"
  :before-close="handleClose">
    <span slot="title"></span>
    <span slot="footer"></span>
</el-dialog>
</template>
<script>
export default {
    props: {
        isShow: {
            typeof: String,
            default: false,
        },
    },
    data() {
        return {
            // dialogVisible: false,
        }
    },
    methods: {
        beforeCreate() {
            console.log('beforeCreate111执行了')
        },
        created() {
            console.log('created111执行了')
        },
        beforeMount() {
            console.log('beforeMount11执行了')
        },
        mounted() {
            console.log('mounted111执行了')
        },
        beforeUpdate() {
            console.log('beforeUpdate111执行了')
            console.log(this.form)
        },
        updated() {
            console.log('updated111执行了')
            console.log(this.form)
        },
        beforeDestroy() {
            console.log('beforeDestroy111执行了')
        },
        destroyed() {
            console.log('destroyed11执行了')
        },
        handleClose(done) {
            this.$confirm('确认关闭？')
            .then(_ => {
                done()
            })
            .catch(_ => {})
        },
    },
}
</script>